/*
* @(#)DmsDocumentDetail.java
*
* Copyright (c) 2003 DCIVision Ltd
* All rights reserved.
*
* This software is the confidential and proprietary information of DCIVision
* Ltd ("Confidential Information").  You shall not disclose such Confidential
* Information and shall use it only in accordance with the terms of the license
* agreement you entered into with DCIVision Ltd.
 */
package com.dcivision.dms.bean;

import java.sql.Timestamp;

import com.dcivision.framework.bean.AbstractBaseObject;

/**
  DmsDocumentDetail.java

  This class is the serializable bean reflecting business logic uses.

    @author           Zoe Shum
    @company          DCIVision Limited
    @creation date    14/08/2003
    @version          $Revision: 1.11 $
    */

public class DmsDocumentDetail extends AbstractBaseObject {

  public static final String REVISION = "$Revision: 1.11 $";

  static final long serialVersionUID = 5246886570045023049L;

  private Integer documentID = null;
  private Integer userDefinedFieldID = null;
  private Integer userDefinedFieldDetailID = null;
  private String fieldValue = null;
  private Double numericValue = null;
  private Timestamp dateValue = null;
  private Timestamp updateDate = null;

  /* parameter for advance search*/
  private Timestamp toDateValue = null;
  private String  toFieldValue = null;
  private Double toNumericValue = null;
  private String fieldType = null;
  private String searchOption = "AND";
  private boolean exactMatch = false;

  public DmsDocumentDetail() {
    super();
  }

  public Integer getDocumentID() {
    return(this.documentID);
  }

  public void setDocumentID(Integer documentID) {
    this.documentID = documentID;
  }

  public Integer getUserDefinedFieldID() {
    return(this.userDefinedFieldID);
  }

  public void setUserDefinedFieldID(Integer userDefinedFieldID) {
    this.userDefinedFieldID = userDefinedFieldID;
  }

  public Integer getUserDefinedFieldDetailID() {
    return(this.userDefinedFieldDetailID);
  }

  public void setUserDefinedFieldDetailID(Integer userDefinedFieldDetailID) {
    this.userDefinedFieldDetailID = userDefinedFieldDetailID;
  }

  public String getFieldValue() {
    return(this.fieldValue);
  }

  public void setFieldValue(String fieldValue) {
    this.fieldValue = fieldValue;
  }

  public Timestamp getDateValue() {
    return(this.dateValue);
  }

  public Double getNumericValue() {
    return(this.numericValue);
  }

  public void setNumericValue(Double numericValue) {
    this.numericValue = numericValue;
  }

  public void setDateValue(Timestamp dateValue) {
    this.dateValue = dateValue;
  }

  public Timestamp getUpdateDate() {
    return(this.updateDate);
  }

  public void setUpdateDate(Timestamp updateDate) {
    this.updateDate = updateDate;
  }

  public Timestamp getToDateValue() {
    return(this.toDateValue);
  }

  public void setToDateValue(Timestamp toDateValue) {
    this.toDateValue = toDateValue;
  }

  public String getToFieldValue() {
    return(this.toFieldValue);
  }

  public void setToFieldValue(String toFieldValue) {
    this.toFieldValue = toFieldValue;
  }

  public Double getToNumericValue() {
    return (this.toNumericValue);
  }

  public void setToNumericValue(Double toNumericValue) {
    this.toNumericValue = toNumericValue;
  }

  public void setFieldType(String fieldType) {
    this.fieldType = fieldType;
  }

  public String getFieldType() {
    return(this.fieldType);
  }

  public void setSearchOption(String searchOption){
    this.searchOption = searchOption;
  }

  public String getSearchOption(){
    if (!"OR".equals(searchOption)){
      searchOption="AND";
    }
    return this.searchOption;
  }

  public void setExactMatch (boolean exactMatch){
    this.exactMatch = exactMatch;
  }

  public boolean getExactMatch(){
    return this.exactMatch;
  }
}
